package com.mmlc.meimei.lichengkongjian.Adapter;

import android.content.Context;
import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.TextView;

import com.mmlc.meimei.lichengkongjian.R;
import com.mmlc.network.responsebean.ShopOrderPayTypeResponseBean;

import java.util.ArrayList;

public class ShopOrderInfoAdapter extends BaseAdapter {

    ArrayList<ShopOrderPayTypeResponseBean.DataBean.ExtInfoBean> voucherInfo;
    Context context;
    public ShopOrderInfoAdapter(Context context , ArrayList<ShopOrderPayTypeResponseBean.DataBean.ExtInfoBean> voucherInfo) {
        this.voucherInfo = voucherInfo;
        this.context = context;
    }

    @Override
    public int getCount() {
        return voucherInfo.size();
    }

    @Override
    public Object getItem(int position) {
        return null;
    }

    @Override
    public long getItemId(int position) {
        return 0;
    }

    @Override
    public View getView(int position, View convertView, ViewGroup parent) {

        if(convertView == null){
            convertView = View.inflate(context, R.layout.adapter_order_pay_method_info, null);
        }
        TextView tv_title = (TextView) convertView.findViewById(R.id.tv_title);
        tv_title.setText(voucherInfo.get(position).getValue());
        return convertView;
    }
}

